import React, { useEffect, useState } from 'react'

const List = ({value}) => {
    
    const [data,setData] = useState([])

    useEffect(()=>{
        const data = []
        data.length = 10000
        for (let i = 0; i < data.length; i++) {
            data.fill(i + 1, i)            
        }
        // console.log(data);
        setData(data)
    },[value])
  return (
    <div>
        {data.map(item => {
            return <p key={item}>{value}</p>
        })}
    </div>
  )
}

export default List